<?php

namespace App\Http\Controllers\Web;

use App\Http\Controllers\Controller;
use App\Models\Music;
use Illuminate\Http\Request;

class MusicController extends Controller
{
    public function index(Request $request)
    {
        $id = $request->get('id');
        $music = Music::find($id);
        $title = $music['title'];
        $author = $music['author'];
        $cover = $music['cover'];
        $url = $music['url'];
        return view('tools.music.index', compact('title', 'url', 'cover', 'author'));
    }
}
